package kassiopeia.gui.task

import java.util.SortedSet;

class Task implements Comparable {

    static hasMany = [plugins:Plugin, connections:Connection]

    static constraints = {
        name(unique:true)
    }

    static mapping = {
        plugins(lazy:false)
        connections(lazy:false)
    }

    Date dateCreated

    String name
    String description
    SortedSet plugins
    SortedSet connections

    int compareTo(obj) {
        dateCreated.compareTo(obj.dateCreated)
    }
}

